import request from '@/utils/request'
//查看报告
export function getReportDetail(id){
  return request({
    url:'/system/report/info/'+id,
    method:'get'
  })
}

//删除报告：批量删除
export function deleteReports(ids){
  return request({
    url:'/system/report/'+ids,
    method:'delete'
  })
}
//导出报告:路径参数使用+id表示嘛
export function exportReport(id){
    return request({
      url:'/system/report/export/'+id,
      method:'get',
      responseType:"blob"//使其可以处理二进制数据
    })
}

// 获取报告列表：需要传入多个Param参数，参数从input框中获取
export function fetchReportList(param) {
  return request({
    url: '/system/report/list',
    method: 'get',
    params:param
  })
}

// 获取验证码
export function getCodeImg() {
  return request({
    url: '/captchaImage',
    headers: {
      isToken: false
    },
    method: 'get',
    timeout: 20000
  })
}
